<!-- Main content -->
<section class="content">
	<div class="row">
		<!-- right column -->
		<div class="col-md-12">
		
			<!-- general form elements disabled -->
			<div class="box box-alegro">
			
			<?php 
			if ($this->session->flashdata('visualizarCliente')){
				$html = '<div class="alert alert-danger alert-dismissable">
							<i class="fa fa-warning"></i>' . $this->session->flashdata('visualizarCliente') . '</div>';
				echo $html;
			}

			$cliente = json_decode($cliente);
			
			//echo "<pre>";
			foreach ($cliente as $key=>$value){
				//print_r($key . " - " . $value);
				if ($cliente->$key == "" || $cliente->$key == null ){
					$cliente->$key = "";
				}
				if ($cliente->Tipo == 'J'){
					$cliente->Tipo = "Pessao Jurídica";
				} else if ($cliente->Tipo == 'F'){
					$cliente->Tipo = "Pessao Física";
				}
				//echo "<br>";
			}
			
			?>
			
				<div class="box-body">
					<!-- text input -->
					<div class="row">
						<div class="form-group col-md-5">
							<label>Nome</label>
							<input type="text" disabled="disabled" value="<?php echo $cliente->Nome?>" class="form-control" />
						</div>
						<div class="form-group col-md-4">
							<label>Endereço</label> 
							<input type="text" disabled="disabled" value="<?php echo $cliente->Endereco?>" class="form-control" />
						</div>
						<div class="form-group col-md-3">
							<label>Complemento</label> 
							<input type="text" disabled="disabled" value="<?php echo $cliente->Complemento?>" class="form-control" />
						</div>
					</div>
						
					<div class="row">
						<div class="form-group col-md-3">
							<label>Bairro</label>
							<input type="text" disabled="disabled" value="<?php echo $cliente->Bairro?>" class="form-control" />
						</div>
						<div class="form-group col-md-2">
							<label>UF</label> 
							<input type="text" disabled="disabled" value="<?php echo $cliente->UF?>" class="form-control" />
						</div>
						<div class="form-group col-md-3">
							<label>Cidade</label>
							<input type="text" disabled="disabled" value="<?php echo $cliente->Cidade?>" class="form-control" />
						</div>
						<div class="form-group col-md-2">
							<label>CEP</label>
							<input type="text" disabled="disabled" value="<?php echo $cliente->CEP?>" class="form-control" /> 
						</div>
						<div class="form-group col-md-2">
							<label>Tipo de Cliente</label> 
							<input type="text" disabled="disabled" value="<?php echo $cliente->Tipo?>" class="form-control" />
						</div>
					</div>
						
					<div class="row">
						<div class="form-group col-md-4">
							<label>Nome Fantasia</label>
							<input type="text" disabled="disabled" value="<?php echo $cliente->Fantasia?>" class="form-control" />
						</div>
						<div class="form-group col-md-3">
							<label>Inscrição</label> 
							<input type="text" disabled="disabled" value="<?php echo $cliente->Inscricao?>" class="form-control" />
						</div>
						<div class="form-group col-md-3">
							<label>CGC</label> 
							<input type="text" disabled="disabled" value="<?php echo $cliente->CGC?>" class="form-control" />
						</div>
					</div>
					
					<div class="row">
						<div class="form-group col-md-4">
							<label>Contato</label> 
							<input type="text" disabled="disabled" value="<?php echo $cliente->Contato?>" class="form-control" />
						</div>
						<div class="form-group col-md-3">
							<label>Fone</label>
							<input type="text" disabled="disabled" value="<?php echo $cliente->Fone?>" class="form-control" /> 
						</div>
						<div class="form-group col-md-3">
							<label>E-mail</label>
							<input type="text" disabled="disabled" value="<?php echo $cliente->Email?>" class="form-control" />
						</div>
					</div>
						
					<div class="row">
						<!-- textarea -->
						<div class="form-group col-md-12">
							<label>Observação</label>
							<textarea class="form-control" disabled="disabled" rows="3">
							<?php echo $cliente->Observacao?>
							</textarea>
						</div>
					</div>

					<button type="button" class="btn btnAdminAlegro" onClick="history.go(-1)">{botaovoltar}</button>
				</div>
				<!-- /.box-body -->
				
			</div>
			<!-- /.box -->
		</div>
		<!--/.col (right) -->
	</div>
	<!-- /.row -->
</section>
<!-- /.content -->
